3.444 \(\int (a+a \sin (e+f x))^3 (c+d \sin (e+f x))^3 \, dx\)

Optimal. Leaf size=215 \[ -\frac{a^3 d \left (18 c^2+54 c d+23 d^2\right ) \sin ^3(e+f x) \cos (e+f x)}{24 f}-\frac{a^3 \left (90 c^2 d+24 c^3+78 c d^2+23 d^3\right ) \sin (e+f x) \cos (e+f x)}{16 f}+\frac{1}{16} a^3 x \left (90 c^2 d+40 c^3+78 c d^2+23 d^3\right )-\frac{3 a^3 d^2 (c+d) \cos ^5(e+f x)}{5 f}+\frac{a^3 (c+d)^2 (c+7 d) \cos ^3(e+f x)}{3 f}-\frac{4 a^3 (c+d)^3 \cos (e+f x)}{f}-\frac{a^3 d^3 \sin ^5(e+f x) \cos (e+f x)}{6 f} \]

[Out]

(a^3*(40*c^3 + 90*c^2*d + 78*c*d^2 + 23*d^3)*x)/16 - (4*a^3*(c + d)^3*Cos[e + f*x])/f + (a^3*(c + d)^2*(c + 7*
d)*Cos[e + f*x]^3)/(3*f) - (3*a^3*d^2*(c + d)*Cos[e + f*x]^5)/(5*f) - (a^3*(24*c^3 + 90*c^2*d + 78*c*d^2 + 23*
d^3)*Cos[e + f*x]*Sin[e + f*x])/(16*f) - (a^3*d*(18*c^2 + 54*c*d + 23*d^2)*Cos[e + f*x]*Sin[e + f*x]^3)/(24*f)
 - (a^3*d^3*Cos[e + f*x]*Sin[e + f*x]^5)/(6*f)

________________________________________________________________________________________

Rubi [A]  time = 0.544649, antiderivative size = 326, normalized size of antiderivative = 1.52, number of steps used = 6, number of rules used = 5, integrand size = 25, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.2, Rules used = {2763, 2968, 3023, 2753, 2734} \[ -\frac{a^3 \left (107 c^3 d^2+472 c^2 d^3-18 c^4 d+2 c^5+456 c d^4+136 d^5\right ) \cos (e+f x)}{60 d^2 f}-\frac{a^3 \left (2 c^2-18 c d+115 d^2\right ) \cos (e+f x) (c+d \sin (e+f x))^3}{120 d^2 f}-\frac{a^3 \left (-18 c^2 d+2 c^3+111 c d^2+136 d^3\right ) \cos (e+f x) (c+d \sin (e+f x))^2}{120 d^2 f}-\frac{a^3 \left (216 c^2 d^2-36 c^3 d+4 c^4+626 c d^3+345 d^4\right ) \sin (e+f x) \cos (e+f x)}{240 d f}+\frac{1}{16} a^3 x \left (90 c^2 d+40 c^3+78 c d^2+23 d^3\right )+\frac{a^3 (2 c-13 d) \cos (e+f x) (c+d \sin (e+f x))^4}{30 d^2 f}-\frac{\cos (e+f x) \left (a^3 \sin (e+f x)+a^3\right ) (c+d \sin (e+f x))^4}{6 d f} \]

Antiderivative was successfully verified.

[In]

Int[(a + a*Sin[e + f*x])^3*(c + d*Sin[e + f*x])^3,x]

[Out]

(a^3*(40*c^3 + 90*c^2*d + 78*c*d^2 + 23*d^3)*x)/16 - (a^3*(2*c^5 - 18*c^4*d + 107*c^3*d^2 + 472*c^2*d^3 + 456*
c*d^4 + 136*d^5)*Cos[e + f*x])/(60*d^2*f) - (a^3*(4*c^4 - 36*c^3*d + 216*c^2*d^2 + 626*c*d^3 + 345*d^4)*Cos[e
+ f*x]*Sin[e + f*x])/(240*d*f) - (a^3*(2*c^3 - 18*c^2*d + 111*c*d^2 + 136*d^3)*Cos[e + f*x]*(c + d*Sin[e + f*x
])^2)/(120*d^2*f) - (a^3*(2*c^2 - 18*c*d + 115*d^2)*Cos[e + f*x]*(c + d*Sin[e + f*x])^3)/(120*d^2*f) + (a^3*(2
*c - 13*d)*Cos[e + f*x]*(c + d*Sin[e + f*x])^4)/(30*d^2*f) - (Cos[e + f*x]*(a^3 + a^3*Sin[e + f*x])*(c + d*Sin
[e + f*x])^4)/(6*d*f)

Rule 2763

Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)])^(n_), x_Symbol] :> -Si
mp[(b^2*Cos[e + f*x]*(a + b*Sin[e + f*x])^(m - 2)*(c + d*Sin[e + f*x])^(n + 1))/(d*f*(m + n)), x] + Dist[1/(d*
(m + n)), Int[(a + b*Sin[e + f*x])^(m - 2)*(c + d*Sin[e + f*x])^n*Simp[a*b*c*(m - 2) + b^2*d*(n + 1) + a^2*d*(
m + n) - b*(b*c*(m - 1) - a*d*(3*m + 2*n - 2))*Sin[e + f*x], x], x], x] /; FreeQ[{a, b, c, d, e, f, n}, x] &&
NeQ[b*c - a*d, 0] && EqQ[a^2 - b^2, 0] && NeQ[c^2 - d^2, 0] && GtQ[m, 1] &&  !LtQ[n, -1] && (IntegersQ[2*m, 2*
n] || IntegerQ[m + 1/2] || (IntegerQ[m] && EqQ[c, 0]))

Rule 2968

Int[((a_.) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.)*((A_.) + (B_.)*sin[(e_.) + (f_.)*(x_)])*((c_.) + (d_.)*sin[(
e_.) + (f_.)*(x_)]), x_Symbol] :> Int[(a + b*Sin[e + f*x])^m*(A*c + (B*c + A*d)*Sin[e + f*x] + B*d*Sin[e + f*x
]^2), x] /; FreeQ[{a, b, c, d, e, f, A, B, m}, x] && NeQ[b*c - a*d, 0]

Rule 3023

Int[((a_.) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.)*((A_.) + (B_.)*sin[(e_.) + (f_.)*(x_)] + (C_.)*sin[(e_.) + (
f_.)*(x_)]^2), x_Symbol] :> -Simp[(C*Cos[e + f*x]*(a + b*Sin[e + f*x])^(m + 1))/(b*f*(m + 2)), x] + Dist[1/(b*
(m + 2)), Int[(a + b*Sin[e + f*x])^m*Simp[A*b*(m + 2) + b*C*(m + 1) + (b*B*(m + 2) - a*C)*Sin[e + f*x], x], x]
, x] /; FreeQ[{a, b, e, f, A, B, C, m}, x] &&  !LtQ[m, -1]

Rule 2753

Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)]), x_Symbol] :> -Simp[(d
*Cos[e + f*x]*(a + b*Sin[e + f*x])^m)/(f*(m + 1)), x] + Dist[1/(m + 1), Int[(a + b*Sin[e + f*x])^(m - 1)*Simp[
b*d*m + a*c*(m + 1) + (a*d*m + b*c*(m + 1))*Sin[e + f*x], x], x], x] /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[b*
c - a*d, 0] && NeQ[a^2 - b^2, 0] && GtQ[m, 0] && IntegerQ[2*m]

Rule 2734

Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)]), x_Symbol] :> Simp[((2*a*c
+ b*d)*x)/2, x] + (-Simp[((b*c + a*d)*Cos[e + f*x])/f, x] - Simp[(b*d*Cos[e + f*x]*Sin[e + f*x])/(2*f), x]) /;
 FreeQ[{a, b, c, d, e, f}, x] && NeQ[b*c - a*d, 0]

Rubi steps

\begin{align*} \int (a+a \sin (e+f x))^3 (c+d \sin (e+f x))^3 \, dx &=-\frac{\cos (e+f x) \left (a^3+a^3 \sin (e+f x)\right ) (c+d \sin (e+f x))^4}{6 d f}+\frac{\int (a+a \sin (e+f x)) \left (a^2 (c+10 d)-a^2 (2 c-13 d) \sin (e+f x)\right ) (c+d \sin (e+f x))^3 \, dx}{6 d}\\ &=-\frac{\cos (e+f x) \left (a^3+a^3 \sin (e+f x)\right ) (c+d \sin (e+f x))^4}{6 d f}+\frac{\int (c+d \sin (e+f x))^3 \left (a^3 (c+10 d)+\left (-a^3 (2 c-13 d)+a^3 (c+10 d)\right ) \sin (e+f x)-a^3 (2 c-13 d) \sin ^2(e+f x)\right ) \, dx}{6 d}\\ &=\frac{a^3 (2 c-13 d) \cos (e+f x) (c+d \sin (e+f x))^4}{30 d^2 f}-\frac{\cos (e+f x) \left (a^3+a^3 \sin (e+f x)\right ) (c+d \sin (e+f x))^4}{6 d f}+\frac{\int (c+d \sin (e+f x))^3 \left (-3 a^3 (c-34 d) d+a^3 \left (2 c^2-18 c d+115 d^2\right ) \sin (e+f x)\right ) \, dx}{30 d^2}\\ &=-\frac{a^3 \left (2 c^2-18 c d+115 d^2\right ) \cos (e+f x) (c+d \sin (e+f x))^3}{120 d^2 f}+\frac{a^3 (2 c-13 d) \cos (e+f x) (c+d \sin (e+f x))^4}{30 d^2 f}-\frac{\cos (e+f x) \left (a^3+a^3 \sin (e+f x)\right ) (c+d \sin (e+f x))^4}{6 d f}+\frac{\int (c+d \sin (e+f x))^2 \left (-3 a^3 d \left (2 c^2-118 c d-115 d^2\right )+3 a^3 \left (2 c^3-18 c^2 d+111 c d^2+136 d^3\right ) \sin (e+f x)\right ) \, dx}{120 d^2}\\ &=-\frac{a^3 \left (2 c^3-18 c^2 d+111 c d^2+136 d^3\right ) \cos (e+f x) (c+d \sin (e+f x))^2}{120 d^2 f}-\frac{a^3 \left (2 c^2-18 c d+115 d^2\right ) \cos (e+f x) (c+d \sin (e+f x))^3}{120 d^2 f}+\frac{a^3 (2 c-13 d) \cos (e+f x) (c+d \sin (e+f x))^4}{30 d^2 f}-\frac{\cos (e+f x) \left (a^3+a^3 \sin (e+f x)\right ) (c+d \sin (e+f x))^4}{6 d f}+\frac{\int (c+d \sin (e+f x)) \left (-3 a^3 d \left (2 c^3-318 c^2 d-567 c d^2-272 d^3\right )+3 a^3 \left (4 c^4-36 c^3 d+216 c^2 d^2+626 c d^3+345 d^4\right ) \sin (e+f x)\right ) \, dx}{360 d^2}\\ &=\frac{1}{16} a^3 \left (40 c^3+90 c^2 d+78 c d^2+23 d^3\right ) x-\frac{a^3 \left (2 c^5-18 c^4 d+107 c^3 d^2+472 c^2 d^3+456 c d^4+136 d^5\right ) \cos (e+f x)}{60 d^2 f}-\frac{a^3 \left (4 c^4-36 c^3 d+216 c^2 d^2+626 c d^3+345 d^4\right ) \cos (e+f x) \sin (e+f x)}{240 d f}-\frac{a^3 \left (2 c^3-18 c^2 d+111 c d^2+136 d^3\right ) \cos (e+f x) (c+d \sin (e+f x))^2}{120 d^2 f}-\frac{a^3 \left (2 c^2-18 c d+115 d^2\right ) \cos (e+f x) (c+d \sin (e+f x))^3}{120 d^2 f}+\frac{a^3 (2 c-13 d) \cos (e+f x) (c+d \sin (e+f x))^4}{30 d^2 f}-\frac{\cos (e+f x) \left (a^3+a^3 \sin (e+f x)\right ) (c+d \sin (e+f x))^4}{6 d f}\\ \end{align*}

Mathematica [A]  time = 1.41372, size = 233, normalized size = 1.08 \[ -\frac{a^3 \cos (e+f x) \left (30 \left (90 c^2 d+40 c^3+78 c d^2+23 d^3\right ) \sin ^{-1}\left (\frac{\sqrt{1-\sin (e+f x)}}{\sqrt{2}}\right )+\sqrt{\cos ^2(e+f x)} \left (10 d \left (18 c^2+54 c d+23 d^2\right ) \sin ^3(e+f x)+16 \left (45 c^2 d+5 c^3+57 c d^2+17 d^3\right ) \sin ^2(e+f x)+15 \left (90 c^2 d+24 c^3+78 c d^2+23 d^3\right ) \sin (e+f x)+16 \left (135 c^2 d+55 c^3+114 c d^2+34 d^3\right )+144 d^2 (c+d) \sin ^4(e+f x)+40 d^3 \sin ^5(e+f x)\right )\right )}{240 f \sqrt{\cos ^2(e+f x)}} \]

Antiderivative was successfully verified.

[In]

Integrate[(a + a*Sin[e + f*x])^3*(c + d*Sin[e + f*x])^3,x]

[Out]

-(a^3*Cos[e + f*x]*(30*(40*c^3 + 90*c^2*d + 78*c*d^2 + 23*d^3)*ArcSin[Sqrt[1 - Sin[e + f*x]]/Sqrt[2]] + Sqrt[C
os[e + f*x]^2]*(16*(55*c^3 + 135*c^2*d + 114*c*d^2 + 34*d^3) + 15*(24*c^3 + 90*c^2*d + 78*c*d^2 + 23*d^3)*Sin[
e + f*x] + 16*(5*c^3 + 45*c^2*d + 57*c*d^2 + 17*d^3)*Sin[e + f*x]^2 + 10*d*(18*c^2 + 54*c*d + 23*d^2)*Sin[e +
f*x]^3 + 144*d^2*(c + d)*Sin[e + f*x]^4 + 40*d^3*Sin[e + f*x]^5)))/(240*f*Sqrt[Cos[e + f*x]^2])

________________________________________________________________________________________

Maple [B]  time = 0.051, size = 481, normalized size = 2.2 \begin{align*} \text{result too large to display} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+a*sin(f*x+e))^3*(c+d*sin(f*x+e))^3,x)

[Out]

1/f*(-1/3*a^3*c^3*(2+sin(f*x+e)^2)*cos(f*x+e)+3*a^3*c^2*d*(-1/4*(sin(f*x+e)^3+3/2*sin(f*x+e))*cos(f*x+e)+3/8*f
*x+3/8*e)-3/5*a^3*c*d^2*(8/3+sin(f*x+e)^4+4/3*sin(f*x+e)^2)*cos(f*x+e)+a^3*d^3*(-1/6*(sin(f*x+e)^5+5/4*sin(f*x
+e)^3+15/8*sin(f*x+e))*cos(f*x+e)+5/16*f*x+5/16*e)+3*a^3*c^3*(-1/2*sin(f*x+e)*cos(f*x+e)+1/2*f*x+1/2*e)-3*a^3*
c^2*d*(2+sin(f*x+e)^2)*cos(f*x+e)+9*a^3*c*d^2*(-1/4*(sin(f*x+e)^3+3/2*sin(f*x+e))*cos(f*x+e)+3/8*f*x+3/8*e)-3/
5*a^3*d^3*(8/3+sin(f*x+e)^4+4/3*sin(f*x+e)^2)*cos(f*x+e)-3*a^3*c^3*cos(f*x+e)+9*a^3*c^2*d*(-1/2*sin(f*x+e)*cos
(f*x+e)+1/2*f*x+1/2*e)-3*a^3*c*d^2*(2+sin(f*x+e)^2)*cos(f*x+e)+3*a^3*d^3*(-1/4*(sin(f*x+e)^3+3/2*sin(f*x+e))*c
os(f*x+e)+3/8*f*x+3/8*e)+a^3*c^3*(f*x+e)-3*a^3*c^2*d*cos(f*x+e)+3*a^3*c*d^2*(-1/2*sin(f*x+e)*cos(f*x+e)+1/2*f*
x+1/2*e)-1/3*a^3*d^3*(2+sin(f*x+e)^2)*cos(f*x+e))

________________________________________________________________________________________

Maxima [B]  time = 1.19856, size = 633, normalized size = 2.94 \begin{align*} \frac{320 \,{\left (\cos \left (f x + e\right )^{3} - 3 \, \cos \left (f x + e\right )\right )} a^{3} c^{3} + 720 \,{\left (2 \, f x + 2 \, e - \sin \left (2 \, f x + 2 \, e\right )\right )} a^{3} c^{3} + 960 \,{\left (f x + e\right )} a^{3} c^{3} + 2880 \,{\left (\cos \left (f x + e\right )^{3} - 3 \, \cos \left (f x + e\right )\right )} a^{3} c^{2} d + 90 \,{\left (12 \, f x + 12 \, e + \sin \left (4 \, f x + 4 \, e\right ) - 8 \, \sin \left (2 \, f x + 2 \, e\right )\right )} a^{3} c^{2} d + 2160 \,{\left (2 \, f x + 2 \, e - \sin \left (2 \, f x + 2 \, e\right )\right )} a^{3} c^{2} d - 192 \,{\left (3 \, \cos \left (f x + e\right )^{5} - 10 \, \cos \left (f x + e\right )^{3} + 15 \, \cos \left (f x + e\right )\right )} a^{3} c d^{2} + 2880 \,{\left (\cos \left (f x + e\right )^{3} - 3 \, \cos \left (f x + e\right )\right )} a^{3} c d^{2} + 270 \,{\left (12 \, f x + 12 \, e + \sin \left (4 \, f x + 4 \, e\right ) - 8 \, \sin \left (2 \, f x + 2 \, e\right )\right )} a^{3} c d^{2} + 720 \,{\left (2 \, f x + 2 \, e - \sin \left (2 \, f x + 2 \, e\right )\right )} a^{3} c d^{2} - 192 \,{\left (3 \, \cos \left (f x + e\right )^{5} - 10 \, \cos \left (f x + e\right )^{3} + 15 \, \cos \left (f x + e\right )\right )} a^{3} d^{3} + 320 \,{\left (\cos \left (f x + e\right )^{3} - 3 \, \cos \left (f x + e\right )\right )} a^{3} d^{3} + 5 \,{\left (4 \, \sin \left (2 \, f x + 2 \, e\right )^{3} + 60 \, f x + 60 \, e + 9 \, \sin \left (4 \, f x + 4 \, e\right ) - 48 \, \sin \left (2 \, f x + 2 \, e\right )\right )} a^{3} d^{3} + 90 \,{\left (12 \, f x + 12 \, e + \sin \left (4 \, f x + 4 \, e\right ) - 8 \, \sin \left (2 \, f x + 2 \, e\right )\right )} a^{3} d^{3} - 2880 \, a^{3} c^{3} \cos \left (f x + e\right ) - 2880 \, a^{3} c^{2} d \cos \left (f x + e\right )}{960 \, f} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))^3*(c+d*sin(f*x+e))^3,x, algorithm="maxima")

[Out]

1/960*(320*(cos(f*x + e)^3 - 3*cos(f*x + e))*a^3*c^3 + 720*(2*f*x + 2*e - sin(2*f*x + 2*e))*a^3*c^3 + 960*(f*x
 + e)*a^3*c^3 + 2880*(cos(f*x + e)^3 - 3*cos(f*x + e))*a^3*c^2*d + 90*(12*f*x + 12*e + sin(4*f*x + 4*e) - 8*si
n(2*f*x + 2*e))*a^3*c^2*d + 2160*(2*f*x + 2*e - sin(2*f*x + 2*e))*a^3*c^2*d - 192*(3*cos(f*x + e)^5 - 10*cos(f
*x + e)^3 + 15*cos(f*x + e))*a^3*c*d^2 + 2880*(cos(f*x + e)^3 - 3*cos(f*x + e))*a^3*c*d^2 + 270*(12*f*x + 12*e
 + sin(4*f*x + 4*e) - 8*sin(2*f*x + 2*e))*a^3*c*d^2 + 720*(2*f*x + 2*e - sin(2*f*x + 2*e))*a^3*c*d^2 - 192*(3*
cos(f*x + e)^5 - 10*cos(f*x + e)^3 + 15*cos(f*x + e))*a^3*d^3 + 320*(cos(f*x + e)^3 - 3*cos(f*x + e))*a^3*d^3
+ 5*(4*sin(2*f*x + 2*e)^3 + 60*f*x + 60*e + 9*sin(4*f*x + 4*e) - 48*sin(2*f*x + 2*e))*a^3*d^3 + 90*(12*f*x + 1
2*e + sin(4*f*x + 4*e) - 8*sin(2*f*x + 2*e))*a^3*d^3 - 2880*a^3*c^3*cos(f*x + e) - 2880*a^3*c^2*d*cos(f*x + e)
)/f

________________________________________________________________________________________

Fricas [A]  time = 2.14481, size = 590, normalized size = 2.74 \begin{align*} -\frac{144 \,{\left (a^{3} c d^{2} + a^{3} d^{3}\right )} \cos \left (f x + e\right )^{5} - 80 \,{\left (a^{3} c^{3} + 9 \, a^{3} c^{2} d + 15 \, a^{3} c d^{2} + 7 \, a^{3} d^{3}\right )} \cos \left (f x + e\right )^{3} - 15 \,{\left (40 \, a^{3} c^{3} + 90 \, a^{3} c^{2} d + 78 \, a^{3} c d^{2} + 23 \, a^{3} d^{3}\right )} f x + 960 \,{\left (a^{3} c^{3} + 3 \, a^{3} c^{2} d + 3 \, a^{3} c d^{2} + a^{3} d^{3}\right )} \cos \left (f x + e\right ) + 5 \,{\left (8 \, a^{3} d^{3} \cos \left (f x + e\right )^{5} - 2 \,{\left (18 \, a^{3} c^{2} d + 54 \, a^{3} c d^{2} + 31 \, a^{3} d^{3}\right )} \cos \left (f x + e\right )^{3} + 3 \,{\left (24 \, a^{3} c^{3} + 102 \, a^{3} c^{2} d + 114 \, a^{3} c d^{2} + 41 \, a^{3} d^{3}\right )} \cos \left (f x + e\right )\right )} \sin \left (f x + e\right )}{240 \, f} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))^3*(c+d*sin(f*x+e))^3,x, algorithm="fricas")

[Out]

-1/240*(144*(a^3*c*d^2 + a^3*d^3)*cos(f*x + e)^5 - 80*(a^3*c^3 + 9*a^3*c^2*d + 15*a^3*c*d^2 + 7*a^3*d^3)*cos(f
*x + e)^3 - 15*(40*a^3*c^3 + 90*a^3*c^2*d + 78*a^3*c*d^2 + 23*a^3*d^3)*f*x + 960*(a^3*c^3 + 3*a^3*c^2*d + 3*a^
3*c*d^2 + a^3*d^3)*cos(f*x + e) + 5*(8*a^3*d^3*cos(f*x + e)^5 - 2*(18*a^3*c^2*d + 54*a^3*c*d^2 + 31*a^3*d^3)*c
os(f*x + e)^3 + 3*(24*a^3*c^3 + 102*a^3*c^2*d + 114*a^3*c*d^2 + 41*a^3*d^3)*cos(f*x + e))*sin(f*x + e))/f

________________________________________________________________________________________

Sympy [A]  time = 8.79437, size = 1176, normalized size = 5.47 \begin{align*} \text{result too large to display} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))**3*(c+d*sin(f*x+e))**3,x)

[Out]

Piecewise((3*a**3*c**3*x*sin(e + f*x)**2/2 + 3*a**3*c**3*x*cos(e + f*x)**2/2 + a**3*c**3*x - a**3*c**3*sin(e +
 f*x)**2*cos(e + f*x)/f - 3*a**3*c**3*sin(e + f*x)*cos(e + f*x)/(2*f) - 2*a**3*c**3*cos(e + f*x)**3/(3*f) - 3*
a**3*c**3*cos(e + f*x)/f + 9*a**3*c**2*d*x*sin(e + f*x)**4/8 + 9*a**3*c**2*d*x*sin(e + f*x)**2*cos(e + f*x)**2
/4 + 9*a**3*c**2*d*x*sin(e + f*x)**2/2 + 9*a**3*c**2*d*x*cos(e + f*x)**4/8 + 9*a**3*c**2*d*x*cos(e + f*x)**2/2
 - 15*a**3*c**2*d*sin(e + f*x)**3*cos(e + f*x)/(8*f) - 9*a**3*c**2*d*sin(e + f*x)**2*cos(e + f*x)/f - 9*a**3*c
**2*d*sin(e + f*x)*cos(e + f*x)**3/(8*f) - 9*a**3*c**2*d*sin(e + f*x)*cos(e + f*x)/(2*f) - 6*a**3*c**2*d*cos(e
 + f*x)**3/f - 3*a**3*c**2*d*cos(e + f*x)/f + 27*a**3*c*d**2*x*sin(e + f*x)**4/8 + 27*a**3*c*d**2*x*sin(e + f*
x)**2*cos(e + f*x)**2/4 + 3*a**3*c*d**2*x*sin(e + f*x)**2/2 + 27*a**3*c*d**2*x*cos(e + f*x)**4/8 + 3*a**3*c*d*
*2*x*cos(e + f*x)**2/2 - 3*a**3*c*d**2*sin(e + f*x)**4*cos(e + f*x)/f - 45*a**3*c*d**2*sin(e + f*x)**3*cos(e +
 f*x)/(8*f) - 4*a**3*c*d**2*sin(e + f*x)**2*cos(e + f*x)**3/f - 9*a**3*c*d**2*sin(e + f*x)**2*cos(e + f*x)/f -
 27*a**3*c*d**2*sin(e + f*x)*cos(e + f*x)**3/(8*f) - 3*a**3*c*d**2*sin(e + f*x)*cos(e + f*x)/(2*f) - 8*a**3*c*
d**2*cos(e + f*x)**5/(5*f) - 6*a**3*c*d**2*cos(e + f*x)**3/f + 5*a**3*d**3*x*sin(e + f*x)**6/16 + 15*a**3*d**3
*x*sin(e + f*x)**4*cos(e + f*x)**2/16 + 9*a**3*d**3*x*sin(e + f*x)**4/8 + 15*a**3*d**3*x*sin(e + f*x)**2*cos(e
 + f*x)**4/16 + 9*a**3*d**3*x*sin(e + f*x)**2*cos(e + f*x)**2/4 + 5*a**3*d**3*x*cos(e + f*x)**6/16 + 9*a**3*d*
*3*x*cos(e + f*x)**4/8 - 11*a**3*d**3*sin(e + f*x)**5*cos(e + f*x)/(16*f) - 3*a**3*d**3*sin(e + f*x)**4*cos(e
+ f*x)/f - 5*a**3*d**3*sin(e + f*x)**3*cos(e + f*x)**3/(6*f) - 15*a**3*d**3*sin(e + f*x)**3*cos(e + f*x)/(8*f)
 - 4*a**3*d**3*sin(e + f*x)**2*cos(e + f*x)**3/f - a**3*d**3*sin(e + f*x)**2*cos(e + f*x)/f - 5*a**3*d**3*sin(
e + f*x)*cos(e + f*x)**5/(16*f) - 9*a**3*d**3*sin(e + f*x)*cos(e + f*x)**3/(8*f) - 8*a**3*d**3*cos(e + f*x)**5
/(5*f) - 2*a**3*d**3*cos(e + f*x)**3/(3*f), Ne(f, 0)), (x*(c + d*sin(e))**3*(a*sin(e) + a)**3, True))

________________________________________________________________________________________

Giac [A]  time = 1.41731, size = 504, normalized size = 2.34 \begin{align*} \frac{a^{3} d^{3} \cos \left (3 \, f x + 3 \, e\right )}{12 \, f} - \frac{a^{3} d^{3} \sin \left (6 \, f x + 6 \, e\right )}{192 \, f} - \frac{3 \, a^{3} c d^{2} \sin \left (2 \, f x + 2 \, e\right )}{4 \, f} + \frac{1}{16} \,{\left (24 \, a^{3} c^{3} + 90 \, a^{3} c^{2} d + 54 \, a^{3} c d^{2} + 23 \, a^{3} d^{3}\right )} x + \frac{1}{2} \,{\left (2 \, a^{3} c^{3} + 3 \, a^{3} c d^{2}\right )} x - \frac{3 \,{\left (a^{3} c d^{2} + a^{3} d^{3}\right )} \cos \left (5 \, f x + 5 \, e\right )}{80 \, f} + \frac{{\left (4 \, a^{3} c^{3} + 36 \, a^{3} c^{2} d + 51 \, a^{3} c d^{2} + 15 \, a^{3} d^{3}\right )} \cos \left (3 \, f x + 3 \, e\right )}{48 \, f} - \frac{3 \,{\left (10 \, a^{3} c^{3} + 18 \, a^{3} c^{2} d + 23 \, a^{3} c d^{2} + 5 \, a^{3} d^{3}\right )} \cos \left (f x + e\right )}{8 \, f} - \frac{3 \,{\left (4 \, a^{3} c^{2} d + a^{3} d^{3}\right )} \cos \left (f x + e\right )}{4 \, f} + \frac{3 \,{\left (2 \, a^{3} c^{2} d + 6 \, a^{3} c d^{2} + 3 \, a^{3} d^{3}\right )} \sin \left (4 \, f x + 4 \, e\right )}{64 \, f} - \frac{3 \,{\left (16 \, a^{3} c^{3} + 64 \, a^{3} c^{2} d + 48 \, a^{3} c d^{2} + 21 \, a^{3} d^{3}\right )} \sin \left (2 \, f x + 2 \, e\right )}{64 \, f} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))^3*(c+d*sin(f*x+e))^3,x, algorithm="giac")

[Out]

1/12*a^3*d^3*cos(3*f*x + 3*e)/f - 1/192*a^3*d^3*sin(6*f*x + 6*e)/f - 3/4*a^3*c*d^2*sin(2*f*x + 2*e)/f + 1/16*(
24*a^3*c^3 + 90*a^3*c^2*d + 54*a^3*c*d^2 + 23*a^3*d^3)*x + 1/2*(2*a^3*c^3 + 3*a^3*c*d^2)*x - 3/80*(a^3*c*d^2 +
 a^3*d^3)*cos(5*f*x + 5*e)/f + 1/48*(4*a^3*c^3 + 36*a^3*c^2*d + 51*a^3*c*d^2 + 15*a^3*d^3)*cos(3*f*x + 3*e)/f
- 3/8*(10*a^3*c^3 + 18*a^3*c^2*d + 23*a^3*c*d^2 + 5*a^3*d^3)*cos(f*x + e)/f - 3/4*(4*a^3*c^2*d + a^3*d^3)*cos(
f*x + e)/f + 3/64*(2*a^3*c^2*d + 6*a^3*c*d^2 + 3*a^3*d^3)*sin(4*f*x + 4*e)/f - 3/64*(16*a^3*c^3 + 64*a^3*c^2*d
 + 48*a^3*c*d^2 + 21*a^3*d^3)*sin(2*f*x + 2*e)/f